package Decorator;

import Decorator.basic.Beverage;
import Decorator.drink.DarkRoast;
import Decorator.drink.Espresso;
import Decorator.drink.HouseBlend;
import Decorator.seasoning.Mocha;
import Decorator.seasoning.Soy;
import Decorator.seasoning.Whip;

public class StarBuzzCoffee {

    public static void main(String[] args) {
        //1. 订一杯Espresso，不需要调料，打印出他的描述与加前
        Beverage beverage = new Espresso();
        System.out.println(beverage.getDescription()+"  $"+beverage.cost());

        //2.制造一杯DarkRoast ,添加调料Mocha和Whip
        Beverage beverage2 = new DarkRoast();
        beverage2 = new Mocha(beverage2);
        beverage2 = new Mocha(beverage2);
        beverage2 = new Whip(beverage2);
        System.out.println(beverage2.getDescription()+ "  $"+beverage2.cost());

        //3.制造一杯调料为都将、摩卡、奶泡的HouseBlend
        Beverage beverage3 = new HouseBlend();
        beverage3 = new Soy(beverage3);
        beverage3 = new Mocha(beverage3);
        beverage3 = new Whip(beverage3);
        System.out.println(beverage3.getDescription()+ "  $"+beverage3.cost());



    }

}
